﻿using BCGM.MedicalWisdom.IServices.BASE;
using BCGM.MedicalWisdom.Model;
using BCGM.MedicalWisdom.Model.Models;
using BCGM.MedicalWisdom.Model.ViewModels.Order;
using System.Collections.Generic;
using System.Threading.Tasks;

namespace BCGM.MedicalWisdom.IServices
{
    /// <summary>
    /// IDrugOrderServices  药品订单
    /// </summary>	
    public interface IDrugOrderServices : IBaseServices<DrugOrder>
    {
        /// <summary>
        /// 药品订单详细两表联查显示
        /// </summary>
        /// <returns></returns>
        Task<PageModel<DrugOrderOutputDto>> GetDrugOrder(int pageIndex = 1, int pageSize = 20, string orderByFields = null);
        /// <summary>
        /// sql语句药品订单显示
        /// </summary>
        /// <param name="sql"></param>
        /// <param name="parameters"></param>
        /// <returns></returns>
        Task<List<DrugOrderOutputDto>> GetDrugOrderSql();
        /// <summary>
        /// 药品添加购物车信息
        /// </summary>
        /// <param name="carDto"></param>
        /// <returns></returns>
        Task<bool> AddDrugRedis(DrugCarDto carDto);
        /// <summary>
        /// 获取药品购物车信息
        /// </summary>
        /// <param name="userId"></param>
        /// <returns></returns>
        Task<List<DrugCarDto>> GetDrugCarRedis(string userId);
        /// <summary>
        /// 删除用户药品购物车数据
        /// </summary>
        /// <param name="carDto"></param>
        /// <returns></returns>
        Task<bool> RemoveDrugCarRedis(DrugCarDto carDto);
        /// <summary>
        /// 修改用户购物车药品购买数量
        /// </summary>
        /// <param name="carDto"></param>
        /// <returns></returns>
        Task<bool> UptDrugCarRedis(DrugCarDto carDto);

    }
}